package artibella.ui.combos 
{
	import flash.events.Event;
	
	/**
	 * ...
	 * @author pbordachar
	 */
	
	public class ComboEvent extends Event
	{
		public static const SELECTED	:String = "selected";
		public static const OPENED		:String = "opened";
	
		private var _indice:int;
		private var _text:String;

		public function ComboEvent( type:String, indice:int, text:String, bubbles:Boolean = false, cancelable:Boolean = false ) 
		{
			super( type, bubbles, cancelable );
			
			_indice = indice;
			_text = text;
		}
		
		override public function clone():Event
		{
			return new ComboEvent( type, _indice, _text, bubbles, cancelable );
		}
		
		override public function toString():String
		{
			var str:String = "[ComboEvent type=\""+ type +"\" indice=\""+ _indice +"\" text=\""+ _text +"\" bubbles="+ bubbles +" cancelable="+ cancelable +"]";
			
			return str;
		}
		
		public function get indice():int
		{
			return _indice;
		}
		
		public function get text():String
		{
			return _text;
		}
	}
}
